package com.gdpa.service.impl;

import com.gdpa.entity.DistrArea;
import com.gdpa.entity.DistrBuilding;
import com.gdpa.mapper.DistrBuildingMapper;
import com.gdpa.service.IDistrBuildingService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 * 分销楼盘表 服务实现类
 * </p>
 *
 * @author zsr
 * @since 2018-12-19
 */
@Service
public class DistrBuildingServiceImpl extends ServiceImpl<DistrBuildingMapper, DistrBuilding> implements IDistrBuildingService {
    @Autowired
    DistrBuildingMapper buildingMapper;

    @Override
    public DistrArea AreaIsExist(String area) {
        return buildingMapper.AreaIsExist(area);
    }

    @Override
    public List<DistrBuilding> getAllBuilding(Integer id) {
        return buildingMapper.getAllBuilding(id);
    }

    @Override
    public Integer addBuild(DistrBuilding building) {
        return buildingMapper.addBuild(building);
    }

    @Override
    public List<DistrBuilding> findBuilding(DistrBuilding building) {
        return buildingMapper.findBuilding(building);
    }

    @Override
    public Integer deleteBuild(String id) {
        return buildingMapper.deleteBuild(id);
    }
}
